import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    //可以起一个别名
    alias:'/home_page',
    //给路由命名
    name: 'Home',
    component: Home
  },
 

 //登录
 {
  path:'/signIn',
  name:'SignIn',
  component:() =>import('../views/SignIn.vue')
},

  //我的信息
  {
  path:'/imformation',
  name:'Information',
  component:() =>import('../views/Information.vue')
  },

  //我的博客
  {
    path:"/userblog",
    name:"UserBlog",
    component:() =>import('../views/UserBlog.vue')
  },
  //编辑博客
  {
    path:"writeblog",
    name:"WriteBlog",
    component:()=>import('../views/WriteBlog.vue')
  },

]

const router = new VueRouter({
  routes
})

export default router
